<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
</head>
<body>
  <script>
    function bar(){
      console.log("bar函数被执行了")
      console.log("----------------")
    }
  function foo(){
    //浏览器默认提供给我们的其他函数
    console.log("foo函数执行")
    console.log("Hello World")
    alert("HelloCoderWhy")
    //调用自己定义的函数
    bar()
    //其他代码
    console.log("ahhahahahhhahha")
  }
  
  
  foo()
  
  </script>
</body>
</html>